package ejemplo;

import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Text;
import org.eclipse.swt.widgets.Combo;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.layout.GridData;

public class Insidencias extends Composite {
	public Text textEstado;
	public Text textDescripcion;
	public Text textFecha;
	public Text textTipoIncidencia;
	public Text textActiva;
	public Text textPrioridad;

	/**
	 * Create the composite.
	 * @param parent
	 * @param style
	 */
	public Insidencias(Composite parent, int style) {
		super(parent, style);
		setLayout(new GridLayout(3, false));
		
		Label lblTipo_1 = new Label(this, SWT.NONE);
		lblTipo_1.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblTipo_1.setText("Tipo:");
		
		Combo comboTipo = new Combo(this, SWT.NONE);
		comboTipo.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblDniCliente = new Label(this, SWT.NONE);
		lblDniCliente.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblDniCliente.setText("DNI Cliente:");
		
		Combo comboDni = new Combo(this, SWT.NONE);
		comboDni.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblEstado = new Label(this, SWT.NONE);
		lblEstado.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblEstado.setText("Estado:");
		
		textEstado = new Text(this, SWT.BORDER);
		textEstado.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblFecha = new Label(this, SWT.NONE);
		lblFecha.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblFecha.setText("Fecha:");
		
		textFecha = new Text(this, SWT.BORDER);
		textFecha.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblDescripicin = new Label(this, SWT.NONE);
		lblDescripicin.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblDescripicin.setText("Descripici\u00F3n:");
		
		textDescripcion = new Text(this, SWT.BORDER);
		textDescripcion.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblTipo = new Label(this, SWT.NONE);
		lblTipo.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblTipo.setText("Tipo incidencia:");
		
		textTipoIncidencia = new Text(this, SWT.BORDER);
		textTipoIncidencia.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblActiva = new Label(this, SWT.NONE);
		lblActiva.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblActiva.setText("Activa:");
		
		textActiva = new Text(this, SWT.BORDER);
		textActiva.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Label lblPrioridad = new Label(this, SWT.NONE);
		lblPrioridad.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, true, 1, 1));
		lblPrioridad.setText("Prioridad:");
		
		textPrioridad = new Text(this, SWT.BORDER);
		textPrioridad.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
		
		Composite composite = new Composite(this, SWT.NONE);
		composite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 3, 1));
		composite.setLayout(new GridLayout(3, false));
		
		Button button = new Button(composite, SWT.NONE);
		button.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button.setText("Consultar");
		
		Button button_1 = new Button(composite, SWT.NONE);
		button_1.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button_1.setText("< Anterior");
		button_1.setEnabled(false);
		
		Button button_2 = new Button(composite, SWT.NONE);
		button_2.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button_2.setText("Siguiente >");
		button_2.setEnabled(false);
		
		Button button_3 = new Button(composite, SWT.NONE);
		button_3.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button_3.setText("Insertar");
		
		Button button_4 = new Button(composite, SWT.NONE);
		button_4.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button_4.setText("Actualizar");
		
		Button button_5 = new Button(composite, SWT.NONE);
		button_5.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
		button_5.setText("Eliminar");

	}

	@Override
	protected void checkSubclass() {
		// Disable the check that prevents subclassing of SWT components
	}
}
